package com.grandpa.demo.controller;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.grandpa.demo.model.TestDTO;
import org.apache.tika.Tika;
import org.apache.tika.exception.TikaException;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import java.io.File;
import java.io.IOException;

/**
 * @author tmf
 * @description:
 * @date 2024-10-28
 */
@RestController
public class TestController {

    @PostMapping("/test")
    public String test(@RequestBody TestDTO dto){
        System.out.println(dto);

        return dto.getUserName();
    }
}
